package Sorts;

public class Books {
    private String name;
    private int pages;
    private int degree;
    private int sort;

    Books(String name, int pages, int degree,int sort) {//novel种类代号为0，comic种类代号1，Programming种类代号2
        this.name = name;
        this.pages = pages;
        this.degree = 100;
        this.sort = sort;
    }

    public String getName() {
        return name;
    }
    public void setName(String name) {
        this.name = name;
    }

    public int getPages() {
        return pages;
    }
    public void setPages(int pages) {
        this.pages = pages;
    }

    public int getDegree() {
        return degree;
    }
    public void setDegree(int degree) {
        this.degree = degree;
    }

    public int getSort() {
        return sort;
    }
    public void setSort(int sort) {
        this.sort = sort;
    }


    @Override
    public String toString() {
        return  "书名：" + "《" + name + "》" + ",共" + pages + "页" + ",新旧程度为：" + degree + "%,";
    }

}
